package com.buaa.domain;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

/**
 * Title: 人才POJO <br>
 * Description: <br>
 * Company: BUAA
 *
 * @author 伟宏
 * @date 2017年1月24日
 */
@SuppressWarnings("serial")
@Entity
@Table(name = "talent")
@DynamicInsert(true)
@DynamicUpdate(true)
public class Talent implements Serializable {

	@Id
	@GeneratedValue
	@Column(name = "id")
	private Integer id;

	@Column(name = "name", columnDefinition = "varchar(20) default ''")
	private String name; // 姓名

	@Column(name = "sex", columnDefinition = "char(1) default ''")
	private String sex; // 性别

	@Column(name = "unit_code", columnDefinition = "bigint(13)")
	private Long unit_code; // 所在单位编码

	@Column(name = "title", columnDefinition = "varchar(10) default ''")
	private String title; // 职称

	@Column(name = "specialty", columnDefinition = "varchar(20) default ''")
	private String specialty; // 专长

	@Column(name = "telephone", columnDefinition = "varchar(15) default ''")
	private String telephone; // 固定电话

	@Column(name = "phone", columnDefinition = "char(11) default ''")
	private String phone; // 电话

	@Column(name = "mail", columnDefinition = "varchar(30) default ''")
	private String mail; // 邮件

	public Talent() {
	}

	public Talent(Integer id, String name, String sex, Long unit_code, String title, String specialty,
			String telephone, String phone, String mail) {
		super();
		this.id = id;
		this.name = name;
		this.sex = sex;
		this.unit_code = unit_code;
		this.title = title;
		this.specialty = specialty;
		this.telephone = telephone;
		this.phone = phone;
		this.mail = mail;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public Long getUnit_code() {
		return unit_code;
	}

	public void setUnit_code(Long unit_code) {
		this.unit_code = unit_code;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getSpecialty() {
		return specialty;
	}

	public void setSpecialty(String specialty) {
		this.specialty = specialty;
	}

	public String getTelephone() {
		return telephone;
	}

	public void setTelephone(String telephone) {
		this.telephone = telephone;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getMail() {
		return mail;
	}

	public void setMail(String mail) {
		this.mail = mail;
	}

	@Override
	public String toString() {
		return "Talent [id=" + id + ", name=" + name + ", sex=" + sex + ", unit_code=" + unit_code + ", title=" + title
				+ ", specialty=" + specialty + ", telephone=" + telephone + ", phone=" + phone + ", mail=" + mail + "]";
	}

}
